package com.wk.unreal.yyzxserver.controller;

import com.wk.unreal.yyzxserver.dto.Result;
import com.wk.unreal.yyzxserver.service.BedService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@CrossOrigin
@RestController
@RequestMapping("/bed")
public class BedController {

    @Autowired
    private BedService bedService;

    @GetMapping("/details")
    public Result bedDetails(Integer pageNum, Integer pageSize,@RequestParam(required = false) String customerName) {

        return bedService.findByCustomerNameDedDetails(customerName, pageNum, pageSize);
    }



}
